<?php 
	$userid = $_COOKIE["userid"];
    $videoid = $_POST['videoid'];
	$period = $_POST["period"];
	$time = date("y-m-d h:i:s");
    $watchType = $_POST['watchType'];
    require('config.php');
    $stmt = $connection->prepare('insert into registed_user_watch_video (user_id, time, period, videoid, watchType) values (?, ?, ?, ?, ?)');
    $stmt->bind_param("ssdsi", $userid, $time, $period, $videoid, $watchType);
    $stmt->execute();
?> 
